from pymediawiki.pymediawiki import PyMediaWiki

data = """
== Before you start ==
; MediaWiki is server software.
: As with any software that you expose to the internet, there may be bugs or security problems. Do not install MediaWiki unless you intend to keep up with [http://mail.wikipedia.org/mailman/listinfo/mediawiki-announce security upgrades] (please subscribe to receive announcements of security updates).

*

{{#test:1|2|3}}
 
"""

w = PyMediaWiki()

def testParserHook(*args):
    return unicode(args) 

w.registerFunctionHook('test', testParserHook)

print w.parse(data)
